package com.yl.chainStore.entity.company

import com.baomidou.mybatisplus.annotation.IdType
import com.baomidou.mybatisplus.annotation.TableField
import com.baomidou.mybatisplus.annotation.TableId
import com.baomidou.mybatisplus.annotation.TableName
import com.yl.chainStore.common.enums.TypeEnum
import com.yl.common.annotation.NoArg
import com.yl.common.getContext
import java.util.*

/**
 * <p>
 *
 * </p>
 *
 * @author cxw
 * @since 2022-05-17
 */
@NoArg
@TableName("sick_customer_access_log_model_detail")
    data class SickCustomerAccessLogModelDetail  (

    /**
     * id 随访模版详情id
     */
    @TableId(value = "id", type = IdType.AUTO)
    var id: Long,

    /**
     * 第几次
     */
    @TableField("order_num")
    var orderNum: Int = 1,

    /**
     * 间隔时间
     */
    @TableField("time_number")
    var timeNumber: Int = 1,

    /**
     * 时间类型
     */
    var timeType:TypeEnum = TypeEnum.SICK_CUSTOMER_ACCESS_LOG_MODEL_DETAIL_TIME_TYPE_DAY,

    /**
     * 随访项目
     */
    @TableField("access_item")
    var accessItem: String? = null,

    /**
     * 随访内容
     */
    @TableField("plan_content")
    var planContent: String? = null,

    /**
     * 选择医生类型
     */
    @TableField("doctor_type")
    var doctorType: TypeEnum = TypeEnum.SICK_CUSTOMER_ACCESS_LOG_MODEL_DETAIL_DOCTOR_TYPE_FIRST_SICK_DOCTOR,

    /**
     * 选择随访人类型
     */
    @TableField("deal_user_type")
    var dealUserType: TypeEnum = TypeEnum.SICK_CUSTOMER_ACCESS_LOG_MODEL_DETAIL_DEAL_USER_TYPE_FIRST_SICK_CONSULTANT,

    /**
     * 固定医生id
     */
    @TableField("doctor_id")
    var doctorId: Long? = null,

    /**
     * 固定随访人id
     */
    @TableField("deal_user_id")
    var dealUserId: Long? = null,

    /**
     * 关联模版id
     */
    @TableField("model_id")
    var modelId: Long = 0,

    /**
     * 创建时间
     */
    @TableField("create_time")
    var createTime: Date = Date(),

    /**
     * 创建人
     */
    @TableField("create_user_id")
    var createUserId: Long = getContext().userId,

    /**
     * 最后修改时间
     */
    @TableField("update_time")
    var updateTime: Date = Date(),

    /**
     * 最后修改人
     */
    @TableField("update_user_id")
    var updateUserId: Long = getContext().userId,

    )
